<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>旅游管理页面</title>
    <style>
        * {
            margin: 0px;
            padding: 0px;
        }

        .nav {
            background-color: rgb(74, 60, 94);
            display: flex;
            color: white;
            align-items: center;
        }

        .nav img {
            flex-grow: 0;
        }

        .nav ul {
            flex-grow: 3;
            list-style: none;
            display: flex;
            justify-content: space-around;
            align-items: center;
        }

        .nav .search {
            flex-grow: 1;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .nav .search input {
            outline: none;
            border-radius: 10px;
            padding: 5px 10px;
            border: 1px solid #ccc;
            margin-right: 10px;
        }

        .nav .search button {
            color: #fff;
            background-color: #0d3d71;
            border: none;
            border-radius: 10px;
            padding: 5px 15px;
            cursor: pointer;
            transition: background-color 0.3s;
        }

        .nav .search button:hover {
            background-color: #0056b3;
        }

        .nav .login {
            flex-grow: 1;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
        }

        .nav .login button {
            color: #fff;
            background-color: #28a745;
            border: none;
            border-radius: 10px;
            padding: 5px 15px;
            cursor: pointer;
            transition: background-color 0.3s;
        }

        .nav .login button:hover {
            background-color: #218838;
        }

        .nav ul li:hover {
            color: aqua;
            border-bottom: 1px solid aqua;
        }

        .banner {
            width: 100%;
            height: 750px;
            background-image: url(./img/banner.jpg);
            color: white;
            background-size: cover;
            background-position: center;
            font-family: "方正舒体";
            font-size: 2em;
        }

        .banner .word {
            position: relative;
            top: 250px;
            left: 80px;
            width: 80%;
        }

        .title h1,
        .title h4 {
            text-align: center;
            color: gray;
        }

        .title {
            width: 15%;
            margin: 10px auto;
            margin-top: 50px;
        }

        .content {
            width: 100%;
            height: 520px;
            margin-top: 50px;
            background-color: #f8f2f2;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 0 60px;
        }

        .content .left {
            width: 45%;
        }

        .content .right {
            width: 45%;
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        .content .right img {
            width: 100%;
            height: 300px;
            object-fit: cover;
            margin-bottom: 20px;
            display: none;
        }

        .content .right img.active {
            display: block;
        }

        .tabs {
            display: flex;
            gap: 15px;
        }

        .tab {
            width: 20px;
            height: 20px;
            background-color: #ccc;
            border-radius: 50%;
            cursor: pointer;
            transition: background-color 0.3s;
        }

        .tab:hover,
        .tab.active {
            background-color: #28a745;
        }

        .carousel {
            width: 100%;
            margin: 35px auto;
            overflow: hidden;
            background-color: #f8f2f2;
            position: relative;
        }

        .carousel ul {
            display: flex;
            padding: 0;
            margin: 0;
            width: 100%;
            animation: slide 25s infinite;
        }

        .carousel ul li {
            list-style: none;
            width: 100%;
            flex-shrink: 0;
        }

        .carousel ul li img {
            width: 100%;
            height: 500px;
        }

        @keyframes slide {
            0% {
                transform: translateX(0);
            }

            20% {
                transform: translateX(-100%);
            }

            40% {
                transform: translateX(-200%);
            }

            60% {
                transform: translateX(-300%);
            }

            80% {
                transform: translateX(-400%);
            }

            100% {
                transform: translateX(0);
            }
        }

        .bottom {
            text-align: center;
        }
    </style>
</head>

<body>
    <div class="nav">
        <ul>
            <li>关于我们</li>
            <li>最近游玩</li>
            <li>陆游博客</li>
            <li>出行攻略</li>
            <li>美食分享</li>
        </ul>
        <div class="search">
            <input type="text" placeholder="搜索..." />
            <button>搜索</button>
        </div>
        <div class="login">
            <button>登录</button>
            <button>注册</button>
        </div>
    </div>

    <div class="banner">
        <div class="word">
            <h4>生活不止眼前的苟且</h4>
            <h1>还有诗和远方!!</h1>
        </div>
    </div>

    <div class="title">
        <h1>认识我们</h1>
        <hr />
        <h4>我们的博客网站</h4>
    </div>

    <div class="content">
        <!-- 左侧双语介绍 -->
        <div class="left">
            <h1>We are the best!</h1>
            <h4>我们是最棒的！</h4>
            <p>
                We are a harmonious family, dedicated to building a warm and harmonious environment. Here, respect and understanding are our core values.
                我们是一个和谐的大家庭，致力于创建一个温馨和谐的环境。这里，尊重和理解是我们的核心价值。
            </p>
        </div>

        <!-- 右侧图片和选项卡 -->
        <div class="right">
            <!-- 显示图片 -->
            <img src="./img/img1.jpg" class="active" alt="img1">
            <img src="./img/img2.jpg" alt="img2">
            <img src="./img/img3.jpg" alt="img3">
            <img src="./img/img4.jpg" alt="img4">

            <!-- 选项卡 -->
            <div class="tabs">
                <div class="tab active" data-target="0"></div>
                <div class="tab" data-target="1"></div>
                <div class="tab" data-target="2"></div>
                <div class="tab" data-target="3"></div>
            </div>
        </div>
    </div>

    <div class="carousel">
        <ul>
            <li><img src="./img/img5.jpg" alt="巴黎"></li>
            <li><img src="./img/img12.jpg" alt="巴黎"></li>
            <li><img src="./img/img5.jpg" alt="巴黎"></li>
            <li><img src="./img/img4.jpg" alt="巴黎"></li>
            <li><img src="./img/img5.jpg" alt="巴黎"></li>
        </ul>
    </div>

    <div class="bottom">
        版权所有：&copy;遵义师范学院 | 联系电话：012-152-136 | 招生办：教务系统
    </div>

    <script>
        const tabs = document.querySelectorAll('.tab');
        const images = document.querySelectorAll('.right img');

        tabs.forEach(tab => {
            tab.addEventListener('mouseover', () => {
                // 移除所有图片和选项卡的 active 类
                tabs.forEach(t => t.classList.remove('active'));
                images.forEach(img => img.classList.remove('active'));

                // 获取选项卡对应的图片
                const target = tab.getAttribute('data-target');
                images[target].classList.add('active');
                tab.classList.add('active');
            });
        });
    </script>
</body>

</html>
